#!/usr/bin/python
# Filename: backup_ver1.py

import os
import time

source = [ r'D:\new' , r'D:\new2']
target_dir = r'D:\new'
target = target_dir + time.strftime('%Y%m%d%H%M%S') + '.zip'
#zip_command = "zip -qr '%s' %s" % (target, ' '.join(source))
zip_command = "zip -r %s %s" % (target, ' '.join(source))
print target
print zip_command
print target_dir

if os.system(zip_command) == 0:
    print 'Successful backup to', target
else:
    print 'Backup FAILED'
